import request from '@/utils/request'

export function fetchList(data) {
  return request({
    url: 'borrow-record/getPageBorrowRecord',
    method: 'post',
    data
  })
}
export function fetchArticle(id) {
  return request({
    url: '/vue-element-admin/article/detail',
    method: 'get',
    params: { id }
  })
}

export function fetchPv(pv) {
  return request({
    url: '/vue-element-admin/article/pv',
    method: 'get',
    params: { pv }
  })
}
export function updateBorrowRecord(data) {
  return request({
    url: 'borrow-record/editBorrowRecord',
    method: 'put',
    data
  })
}
export function createBorrowRecord(data) {
  return request({
    url: 'borrow-record/getPageBorrowRecord',
    method: 'post',
    data
  })
}

